﻿using Newtonsoft.Json;
using NLog.Fluent;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Runtime.Serialization;
using System.Text.Json.Serialization;

namespace ThresholdAssistant.WebAPI.Models
{
    /// <summary>
    /// 数据记录列表查询参数模型
    /// </summary>
    public class GetRecordListParam
    {
        /// <summary>
        /// 分组ID
        /// </summary>
        [JsonProperty("group_id"), JsonPropertyName("group_id")]
        //[Required(ErrorMessage = nameof(ErrorResultEnum.GroupIdIsNull))]
        [DataMember]
        public long GroupId { get; set; }

        /// <summary>
        /// 标签ID
        /// </summary>
        [JsonProperty("tag_ids"), JsonPropertyName("tag_ids")]
        //[Required(ErrorMessage = nameof(ErrorResultEnum.GroupIdIsNull))]
        [DataMember]
        public List<long> TagIds { get; set; }

        /// <summary>
        /// 类型(0标签列表，1标签统计，2标签类型统计)
        /// </summary>
        [JsonProperty("type"), JsonPropertyName("type")]
        [DataMember]
        public int Type { get; set; }

        /// <summary>
        /// 数据组
        /// </summary>
        [JsonProperty("site_id"), JsonPropertyName("site_id")]
        [DataMember]
        public long SiteId { get; set; }
    }
}
